#ifndef DEALPROCESS_H
#define DEALPROCESS_H

#include <QObject>
#include <QProcess>

class DealProcess : public QObject {
    Q_OBJECT

public:
    explicit DealProcess(QObject *parent = nullptr);
    ~DealProcess();

    void write(QString data);
    QByteArray exec(QString command, QStringList args);

private:
    QProcess *process;
    QByteArray data_in;

    void init();
};

#endif // DEALPROCESS_H
